﻿using System;

namespace NDK.Motion.MachineResources
{
    [Serializable]
    public class VelocityProfile
    {
        private int _axisId;
        private string _axisName;
        private double _startVel;
        private double _moveVel;
        private double _acc;
        private double _dec;
        private double _pos;
        private double _maxVel;
        private bool _shield = false;
        /// <summary>
        /// 轴名称
        /// </summary>
        public string AxisName
        {
            get
            {
                return _axisName;
            }

            set
            {
                _axisName = value;
            }
        }
        /// <summary>
        /// 是否屏蔽改轴，不需要运动
        /// </summary>
        public bool Shield
        {
            get
            {
                return _shield;
            }

            set
            {
                _shield = value;
            }
        }
        /// <summary>
        /// 起始速度
        /// </summary>
        public double StartVel
        {
            get
            {
                return _startVel;
            }

            set
            {
                _startVel = value;
            }
        }
        /// <summary>
        /// 运行速度
        /// </summary>
        public double MoveVel
        {
            get
            {
                return _moveVel;
            }

            set
            {
                _moveVel = value;
            }
        }
        /// <summary>
        /// 加速度
        /// </summary>
        public double Acc
        {
            get
            {
                return _acc;
            }

            set
            {
                _acc = value;
            }
        }
        /// <summary>
        /// 减速度
        /// </summary>
        public double Dec
        {
            get
            {
                return _dec;
            }

            set
            {
                _dec = value;
            }
        }


        /// <summary>
        /// 轴的坐标
        /// </summary>
        public double Pos
        {
            get
            {
                return _pos;
            }

            set
            {
                _pos = value;
            }
        }
        /// <summary>
        /// 轴号
        /// </summary>
        public int AxisId
        {
            get
            {
                return _axisId;
            }

            set
            {
                _axisId = value;
            }
        }

        public VelocityProfile Clone()
        {
            return this.MemberwiseClone() as VelocityProfile;
        }
    }
}
